<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        main{
            text-align: center;;
        }
        .box{
            display: inline-block;
            width: 200px;
            height: 200px;
            margin-top: 10px;
            background-color: #333;
            animation: ani 5s linear infinite 0s;
        }
        @keyframes ani {
            20%{
                transform: translate(500px,0px);
            }
            40%{
                transform: translate(500px,500px);
            }
            60%{
                transform: translate(0px,500px);
            }
            
            100%{
                transform: translate(0,0);
            }
        }
    </style>
</head>
<body>
    <main>
        <div class="box"></div>
    </main>
</body>
</html>